DISCUSSION
The
ATSUTextDeleted function shortens or removes the style run containing the deletion point and the total length of the text range by the amount of the text deletion. If the deletion point is between two style runs, the first style run is removed. It also removes any soft line breaks that fall within the deleted text.
ATSUTextDeleted then updates drawing caches.
ATSUTextDeleted does not change the memory location or the edge offset of the text. It shifts the text after the deleted text by the appropriate offset (
iDeletedRangeStart +
iDeletedRangeLength).
You are responsible for making sure that the corresponding text is deleted from the text buffer. You are also responsible for disposing of the memory associated with style runs that have been removed by calling the function
ATSUDisposeStyle.